/*
 * @Author: your name
 * @Date: 2019-11-28 17:46:20
 * @LastEditTime: 2019-11-28 20:46:33
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \web\avue-cli\src\api\sysSetup\laboratory.js
 */
import request from "@/router/axios";
import qs from "qs";
/**
 * @description: 实验室条件分页查询
 * @param {object}
 * @return: promise
 */
export const getSupplierList = (data = {}) =>
  request({
    url: "/supplier/v1/pageQuery",
    method: "post",
    data: qs.stringify(data)
  });

/**
 * @description: 实验室列表项修改
 * @param {object}
 * @return: promise
 */
export const updateSupplier = (data = {}) =>
  request({
    url: "/supplier/v1/update",
    method: "post",
    data: qs.stringify(data)
  });

/**
 * @description: 实验室新增
 * @param {object}
 * @return: promise
 */
export const addSupplier = (data = {}) =>
  request({
    url: "/supplier/v1/insert",
    method: "post",
    data: qs.stringify(data)
  });

/**
 * @description: 实验室列表项删除
 * @param {object}
 * @return: promise
 */
export const deleteSupplier = (data = {}) =>
  request({
    url: "/supplier/v1/getById",
    method: "post",
    data: qs.stringify(data)
  });

/**
 * @description: 全查供应商列表
 * @param {object}
 * @return: promise
 */
export const getSupplierAll = (data = {}) =>
    request({
        url: "/supplier/v1/selectAll",
        method: "post",
        data: qs.stringify(data)
    });

/**
 * @description: 供应商类型列表
 * @param {object}
 * @return: promise
 */
export const getSupplierType = (data = {}) =>
  request({
    url: "/supplierType/v1/seleteAll",
    method: "post",
    data: qs.stringify(data)
  });


export const getSupplierTypeList = (data) => request({
    url: "/supplierType/v1/pageQuery",
    method: "post",
    data: qs.stringify(data)
});
export const updateSupplierType = (data) => request({
    url: "/supplierType/v1/update",
    method: "post",
    data: qs.stringify(data)
});
export const addSupplierType = (data) => request({
    url: "/supplierType/v1/insert",
    method: "post",
    data: qs.stringify(data)
});
export const deleteSupplierType = (data) => request({
    url: "/supplierType/v1/getById",
    method: "post",
    data: qs.stringify(data)
});
